{% extends "layout.html" %} 
{% block content %}
  <fieldset class="layui-elem-field layui-field-title">
    <legend>新增用户</legend>
  </fieldset>
  <form class="layui-form" method="post" action="/user/add/" autocomplete="off">
    {% csrf_token %}
    <div class="layui-form-item">
      <label class="layui-form-label">姓名</label>
      <div class="layui-input-block">
        <input type="text" name="name" lay-verify="required" placeholder="请输入姓名" autocomplete="off" class="layui-input">
      </div>
    </div>
    <div class="layui-form-item">
      <label class="layui-form-label">密码</label>
      <div class="layui-input-block">
        <input type="text" name="password" lay-verify="required" placeholder="请输入密码" autocomplete="off" class="layui-input">
      </div>
    </div>
    <div class="layui-form-item">
      <label class="layui-form-label">年龄</label>
      <div class="layui-input-block">
        <input type="text" name="age" lay-verify="required" placeholder="请输入年龄" autocomplete="off" class="layui-input">
      </div>
    </div>
    <div class="layui-form-item">
      <label class="layui-form-label">余额</label>
      <div class="layui-input-block">
        <input type="text" name="account" lay-verify="required" placeholder="请输入余额" autocomplete="off" class="layui-input">
      </div>
    </div>
    <div class="layui-form-item">
      <label class="layui-form-label">入职时间</label>
      <div class="layui-input-block">
        <input type="text" name="create_time" lay-verify="required" class="layui-input" id="ID-laydate-demo" placeholder="请选择入职时间" autocomplete="off" class="layui-input">
<!--        请输入入职时间-->
        <input type="text" name="create_time" lay-verify="required" placeholder="请输入入职时间" autocomplete="off" class="layui-input">
      </div>
    </div>
    <div class="layui-form-item">
      <label class="layui-form-label">性别</label>
      <div class="layui-input-block">
        <select name="gender" lay-filter="aihao">
          {% for item in gender_choices %}
          <option value="{{item.0}}">{{item.1}}</option>
          {% endfor %}
        </select>
      </div>
    </div>

    <div class="layui-form-item">
        <label class="layui-form-label">部门</label>
        <div class="layui-input-inline">
          <select name="depart_id" lay-verify="required" lay-search  >
            {% for item in depart_list %}
            <option value="{{item.id}}">{{item.title}}</option>
            {% endfor %}
          </select>
        </div>
    </div>

    <div class="layui-input-block">
      <button type="submit" class="layui-btn" lay-submit lay-filter="demo1">立即提交</button>
      <button type="reset" class="layui-btn layui-btn-primary">重置</button>
    </div>
  </form>
{% endblock %}